import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:ff_flutter/routes/app_routes.dart';

class UserInfo extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Column(
      crossAxisAlignment: CrossAxisAlignment.center,
      children: [
        // 头像和相机按钮
        Center(
          child: SizedBox(
            width: 319.w,
            height: 319.h,
            child: Stack(
              children: [
                Container(
                  width: 319.w,
                  height: 319.h,
                  decoration: const BoxDecoration(
                    shape: BoxShape.circle,
                  ),
                  child: ClipOval(
                    child: Image.asset(
                      'assets/images/girl.png',
                      fit: BoxFit.cover,
                    ),
                  ),
                ),
                Positioned(
                  right: 0,
                  bottom: 0,
                  child: GestureDetector(
                    onTap: () => Get.toNamed(AppRoutes.PERSONAL_DATA),
                    child: Container(
                      width: 72.w,
                      height: 72.h,
                      decoration: const BoxDecoration(
                        color: Color(0xFFE7568C),
                        shape: BoxShape.circle,
                      ),
                      child: Icon(
                        Icons.camera_alt,
                        color: Colors.white,
                        size: 36.sp,
                      ),
                    ),
                  ),
                ),
              ],
            ),
          ),
        ),
        SizedBox(height: 24.h),
        // 用户名
        Text(
          'ANNA_122',
          style: TextStyle(
            color: Colors.white,
            fontSize: 48.sp,
            fontWeight: FontWeight.bold,
          ),
        ),
        SizedBox(height: 8.h),
        // 用户ID
        Text(
          'ID:012345548787',
          style: TextStyle(
            color: Colors.grey,
            fontSize: 32.sp,
          ),
        ),
        SizedBox(height: 8.h),
        // 职业
        Text(
          'a teacher',
          style: TextStyle(
            color: Colors.white.withOpacity(0.9),
            fontSize: 32.sp,
          ),
        ),
      ],
    );
  }
}
